package com.uetoken.cn.adapter;

import android.content.Context;
import android.support.v4.content.ContextCompat;
import android.widget.LinearLayout;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.uetoken.cn.R;
import com.uetoken.cn.adapter.model.PurchaseDetailTableModel;
import com.uetoken.cn.adapter.model.ShipmentTabelMobel;
import com.uetoken.cn.manager.UEDataManager;

public class ShipmentTabelAdapter extends BaseQuickAdapter<ShipmentTabelMobel, BaseViewHolder> {


    private Context mContext;

    public ShipmentTabelAdapter(Context context) {
        super(R.layout.item_shipment_table_title_2, UEDataManager.getInstance().getShipmentTabelMobelList());
        this.mContext = context;
    }

    @Override
    protected void convert(BaseViewHolder helper, ShipmentTabelMobel item) {
        helper.setBackgroundColor(R.id.tableStripLatout, ContextCompat.getColor(mContext, R.color.durban_White));
        helper.setText(R.id.reciprocalAccountNumber1Tv, item.getID());
        helper.setText(R.id.reciprocalAccountNumber2Tv, item.getAccountNumber());
        helper.setText(R.id.topupCodeTv, item.getTopupCode());
        helper.setText(R.id.denominationBtn, item.getDenomination());
        helper.setText(R.id.timeTv, item.getTime());
    }
}
